package com.mark.dao;

import com.mark.pojo.OrderItem;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface OrderItemMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(OrderItem record);

    int insertSelective(OrderItem record);

    OrderItem selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(OrderItem record);

    int updateByPrimaryKey(OrderItem record);

    List<OrderItem> getOrderListByOrderAndUserId(@Param("orderNo") Long orderNo, @Param("currentUserId") Integer currentUserId);

    int batchInsert(@Param("orderItemList") List<OrderItem> orderItemList);

    List<OrderItem> getByOrderNoUserId(@Param("orderNo") Long orderNo, @Param("currentUserId") Integer currentUserId,@Param("sellerId") Integer sellerId);

    List<OrderItem> getByOrderNo(@Param("orderNo") Long orderNo);

    OrderItem selectBySellerIdAndId (@Param("sellerId") Integer sellerId, @Param("id")Integer id);
}